import request from '@/utils/request'

export function fetchList(query) {
  return request({
    url: '/admin/Config/getAll',
    method: 'get',
    params: query
  })
}

export function getLists(query) {
  return request({
    url: '/admin/Config/index',
    method: 'get',
    params: query
  })
}

export function save(data) {
  return request({
    url: '/admin/Config/save',
    method: 'post',
    data
  })
}

export function disable(data) {
  return request({
    url: '/admin/Config/disable',
    method: 'post',
    data
  })
}

export function enable(data) {
  return request({
    url: '/admin/Config/enable',
    method: 'post',
    data
  })
}

export function create(data) {
  return request({
    url: '/admin/Config/add',
    method: 'post',
    data
  })
}

export function edit(data) {
  return request({
    url: '/admin/Config/edit',
    method: 'post',
    data
  })
}

export function del(data) {
  return request({
    url: '/admin/Config/del',
    method: 'post',
    data
  })
}
